package com.party.core.model.wechat;

import com.party.core.model.BaseModel;

/**
 * 微信消息实体
 * party
 * Created by wei.li
 * on 2016/9/12 0012.
 */
public class WechatMessage extends BaseModel{

    private static final long serialVersionUID = -552761814585865080L;


    //微信消息类型
    private Integer type;

    //消息回复类型
    private String replyType;

    //关键字
    private String key;

    //微信消息内容
    private String content;

    //会员编号
    private String memberId;

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getMemberId() {
        return memberId;
    }

    public void setMemberId(String memberId) {
        this.memberId = memberId;
    }

    public String getKey() {
        return key;
    }

    public void setKey(String key) {
        this.key = key;
    }

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }

    public String getReplyType() {
        return replyType;
    }

    public void setReplyType(String replyType) {
        this.replyType = replyType;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        if (!super.equals(o)) return false;

        WechatMessage that = (WechatMessage) o;

        if (type != null ? !type.equals(that.type) : that.type != null) return false;
        if (replyType != null ? !replyType.equals(that.replyType) : that.replyType != null) return false;
        if (key != null ? !key.equals(that.key) : that.key != null) return false;
        if (content != null ? !content.equals(that.content) : that.content != null) return false;
        return memberId != null ? memberId.equals(that.memberId) : that.memberId == null;

    }

    @Override
    public int hashCode() {
        int result = super.hashCode();
        result = 31 * result + (type != null ? type.hashCode() : 0);
        result = 31 * result + (replyType != null ? replyType.hashCode() : 0);
        result = 31 * result + (key != null ? key.hashCode() : 0);
        result = 31 * result + (content != null ? content.hashCode() : 0);
        result = 31 * result + (memberId != null ? memberId.hashCode() : 0);
        return result;
    }

    @Override
    public String toString() {
        return "WechatMessage{" +
                "type=" + type +
                ", replyType='" + replyType + '\'' +
                ", key='" + key + '\'' +
                ", content='" + content + '\'' +
                ", memberId='" + memberId + '\'' +
                '}';
    }

}
